(function() {
	module('Brick Tests');

	test('Setup OK', function() {
		ok(true);
	});

	test('Wrong Answer', function() {
		var view = new TestView();
		var controller = new BrickController(view);

		controller.startup();
		controller.onSolutionGuess('3');

		ok(view.onFailCalled);
		ok(!view.onSolvedCalled);
	});

	test('Right Answer', function() {
		var view = new TestView();
		var controller = new BrickController(view);

		controller.startup();
		controller.onSolutionGuess('2');

		ok(!view.onFailCalled);
		ok(view.onSolvedCalled);
	});

	function TestView() {
		this.onSolvedCalled = false;
		this.onFailCalled = false;
	}

	TestView.prototype.init = function(controller) {
	};

	TestView.prototype.onSolved = function() {
		this.onSolvedCalled = true;
	};

	TestView.prototype.onFail = function() {
		this.onFailCalled = true;
	};
}());